<!DOCTYPE html>
<html class="um landscape min-width-240px min-width-320px min-width-480px min-width-768px min-width-1024px">
<head>
<title></title>
<meta charset="utf-8">
<meta name="viewport" content="target-densitydpi=device-dpi, width=device-width, initial-scale=1, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0">
<link rel="stylesheet" href="css/ui-base.css?v=202022">
<link rel="stylesheet" href="css/ui-img.css?v=202022">
<link rel="stylesheet" href="css/ui-box.css?v=202022">
<link rel="stylesheet" href="css/ui-color.css?v=202022">
<link rel="stylesheet" href="css/lbbbase.css">
<link rel="stylesheet" href="css/ui-position.css">
<link rel="stylesheet" href="css/difu.css">
<link rel="stylesheet" href="css/project/style.css">
<style>
    .arrr-img{
        width: 1em;
        height: 1em;
        background-image:url('images/arrr2.png');
    }
     .c-0097F3{
        background-color: #0097F3;
    }
     .bg{
        background: -webkit-gradient(linear, 0 0, 0 100%, from(#dadcdd), to(#fff));
        -webkit-box-shadow:0px 1px 1px #c2c3c5 inset
    }
    .w88{width:8.4em;}
    .h100{height:10.0em;}
    .h96{height:9.6em;}
    .h88{height:8.4em;}
    canvas{display:block;}
    .c004B9D{color:#004B9D;}
</style>
</head>
<body class="um-vp c-wh" ontouchstart>
<div id="page_0" class="up ub ub-ver" tabindex="0">
   
    <!-- 内容 -->
    <div id="content" class="content mt5">
        <div class="bc1">
            <div class="ub ub-ac lh16 bd_b p5 fs10 c2 bd_t">
                <div class="ub-f1 tx-l">起始时间</div>
                <div class="ub tx-r mr12">
                    <div class="mr5 c25" id="startTime" onclick="checked_day('startTime')"><span class="fs9">请选择时间</span></div>
                    <div class="ub-img arrr-img mt3"></div>
                </div>
            </div>
            <div class="ub ub-ac lh16 bd_b p5 fs10 c2">
                <div class="ub-f1 tx-l">截止时间</div>
                <div class="ub tx-r mr12">
                    <div class="mr5 c25" id="endTime" onclick="checked_day('endTime')"><span class="fs7">(统计截止当日前4天)&nbsp;</span><span class="fs9">请选择时间</span></div>
                    <div class="ub-img arrr-img mt3"></div>
                </div>
            </div>
        </div>
        <div id="tiptxt"  class="mt6 fs8 t-red" hidden>截止时间不能小于开始时间!</div>
        <div class="mt12" >
            <div id="submitBtn" class="uc-a3 c-0097F3 uinn5 c1 tx-c wtp90 lh10" style="margin: 0 auto;" onclick="query()">查&nbsp;询</div>
        </div>
        <div class="mt40" id="pointshow" hidden onclick="openList()">
            <div class="bg uc-a ub ub-pc ub-ac pr w100 h100 m5" style="margin: 0 auto;">
                <div class="pa l0 t0 ub ub-ac ub-pc w_100 h_100">
                    <canvas class="uc-a w96 h96 bc36" id="point"></canvas>
                </div>
                <div class="uc-a ub-ac ub ub-pc w88 h88 bgc_d">
                    <div class="tx-c" hand="point">
                        <div class="fs14 c004B9D fb" id="pointTxt">-</div>
                        <div class="fs7">当前时段内工分合计</div>
                    </div>
                </div>
            </div>
        </div>
    </div>
    
</div>
<script src="js/appcan.js"></script>
<script src="js/zy_control.js?v=202022"></script>
<script src="js/zy_click.js?v=202022"></script>
<script src="js/jquery-1.11.1.min.js?v=202022"></script>
<script src="js/canvas.js?v=202022"></script>
<script src="js/staff.js?v=202022"></script>
<script src="js/main.js?v=202022"></script>
<script>
zy_init();
window.uexOnload = function(type){
    if (!type) {
       // $("#startTime").text("2016-09-30") ;
       // $("#startTime").text(getNowFormatDate()) ;
       // $("#endTime").text(getNowFormatDate()) ;
       // $("#endTime").removeClass("c25 fs7") ;
       $("#pointshow").hide();
       Canvas.arc("point",1.00,"3",0.5);
       
    };
}; 
var queryRateURL="http://flymt.ceair.com/achievements/queryRate?";
function query()
{
    $("#pointshow").hide();
    var startime=$("#startTime").text();
    var endtime=$("#endTime").text();
    if(startime>endtime){
        $("#tiptxt").show();
        return;
    }
    var userId = localStorage['MU30-lOGIN-USRNAME'];
    // alert("userId: "+userId)
    //test
    // var userId="yinzhihua";
    // startime="2016-08-01";
    // endtime="2016-09-26";
    Loading(0);
    $.ajax({ 
             type: "GET",
             url: queryRateURL+"no="+userId+"&startTime="+startime+"&endTime="+endtime,
             data:'',
             dataType: "json",
             success: function(json){
                  // console.log(JSON.stringify(json));
                  localStorage.setItem("PointQueryData",JSON.stringify(json));
                  Loading(-1);
                  if(json.status==0)
                  {
                      $("#tiptxt").hide();
                      $("#pointshow").show();
                      $("#pointTxt").text(json.workpoints);
                  }
             },
             error: function(erro){
                alert(JSON.stringify(erro));
             }
         });
    
    
}
function openList()
{
    appcan.window.open({
                        name:'pointList',
                        dataType:0,
                        data:'pointList.html'
                     });
}
</script>
</body>
</html>